	package com.niuwa.p2p.entity.resource;
	
	import java.io.Serializable;
	
	import javax.persistence.Entity;
	
	
	
	@Entity
	public class Resource  implements Serializable {
	    @Override
		public String toString() {
			return "Resource [id=" + id + ", number=" + number + ", name="
					+ name + ", url=" + url + ", status=" + status
					+ ", description=" + description + ", sort=" + sort
					+ ", pid=" + pid + ", level=" + level + "]";
		}

		/**
		 * 
		 */
		private static final long serialVersionUID = 1L;
		//主键ID
		private int id;
		//资源编号
		private String number;
		//资源名称
		private String name;
		//资源URL
		private String url;
		//资源状态
		private Character status;
		//资源描述
		private String description;
		//资源排序
		private String sort;
		//父资源ID
		private String pid;
		//资源等级
		private int level;
	
		public int getId() {
			return id;
		}
	
		public void setId(int id) {
			this.id = id;
		}
	
		public String getName() {
			return name;
		}
	
		public void setName(String name) {
			this.name = name;
		}
	
		public String getUrl() {
			return url;
		}
	
		public void setUrl(String url) {
			this.url = url;
		}
	
		public Character getStatus() {
			return status;
		}
	
		
	
		public void setStatus(Character status) {
			this.status = status;
		}

		public String getDescription() {
			return description;
		}
	
		public void setDescription(String description) {
			this.description = description;
		}
	
		public String getSort() {
			return sort;
		}
	
		public void setSort(String sort) {
			this.sort = sort;
		}
	
	
	
		public String getPid() {
			return pid;
		}
	
		public void setPid(String pid) {
			this.pid = pid;
		}
	
		public int getLevel() {
			return level;
		}
	
	
		
	
	
		@Override
		public boolean equals(Object obj) {
			if (this == obj)
				return true;
			if (obj == null)
				return false;
			if (getClass() != obj.getClass())
				return false;
			Resource other = (Resource) obj;
			if (url == null) {
				if (other.url != null)
					return false;
			} else if (!url.equals(other.url))
				return false;
			return true;
		}
	
		public void setLevel(int level) {
			this.level = level;
		}
	
		public String getNumber() {
			return number;
		}
	
		public void setNumber(String number) {
			this.number = number;
		}
	
	}
